// 商品详情api
import request from '@/utils/request'

// 商品详情
export const findGoods = (id) => {
  return request('/goods', 'get', { id })
}

// 商品详情
export const findRelGoods = (id, limit = 16) => {
  return request('/goods/relevant', 'get', { id, limit })
}

// 商品详情
export const findHotGoods = (id, limit = 3, type) => {
  return request('/goods/hot', 'get', { id, limit, type })
}

// 获取评价信息
export const findCommentInfoByGoods = (id) => {
  return request(`https://mock.boxuegu.com/mock/1175/goods/${id}/evaluate`, 'get')
}

// 获取评价内容
export const findCommentListByGoods = (id, param) => {
  return request(`https://mock.boxuegu.com/mock/1175/goods/${id}/evaluate/page`, 'get', { param })
}
